package com.campus.service.impl;

import com.campus.service.AssistantService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Service;

/**
 * @author HLQ
 * @date 2024/11/20 17:33
 */
@Slf4j
@Service
public class AssistantServiceImpl implements AssistantService {
    @Autowired
    JdbcTemplate jdbcTemplate;

    @Override
    public int addClassStudentGroup(int classId,int studentId, int groupId) {
        String sql = "insert into t_teaching_student_in_class (class_id,student_id,group_id) values (?,?,?)";
        return jdbcTemplate.update(sql,classId,studentId,groupId);
    }
}
